package com.example.stu.kudestu.stu.service;

import com.example.stu.kudestu.stu.entity.Student;
import org.springframework.data.domain.Page;

import java.util.List;

public interface StudentService {

    //保存
    Student save(Student student);
    //修改
    Student update(Student student);
    //删除
    void delete(Integer id);
    //根据id查询
    Student findStuById(Integer id);
    //根据名字查询
    List<Student> fingStuByName(String name);

    /**
     * 分页查询所有
     * @param page
     * @param pagesize
     * @return
     */
    Page<Student> findAll(int page,int pagesize);

}
